home *** CD-ROM | disk | FTP | other *** search
/ PC-SIG: World of Games / PC-SIG World of Games (CDRM1080710) (1993).iso / ENT / DISK1232.ZIP / ELF-SRC.ZOO / elf.cmd next >
OS/2 REXX Batch file  |  1988-07-07  |  27KB  |  955 lines

  1.  
  2.  
  3. ;COMMENTS
  4. ; Flag 1 is OFF at start of game and ON otherwise
  5. ; Flag 2 is ON if lantern is ON and OFF otherwise
  6. ; Flag 3 is ON if Cooler and beer are warm
  7. ; Flag 4 is ON if NOZEGLOZE condition is true
  8. ; Flag 5 is ON if it is snowing and OFF otherwise
  9. ; Variable 1 will count down the life of the lantern
  10. ; Variable 2 count of turns at South Pole without a parka
  11. ; Variable 3 count of number of turns that Penguin has been following player
  12. ; Counter 1 counts turns since cooler was opened
  13. ; Counter 2 counts turns since snowflake fell
  14. ; Counter 3 counts turns since thermometer was put in cooler
  15.  
  16.  
  17. ; ANY COMMANDS -- Considered for ANY combination of words -- i.e., each turn
  18.  
  19.  
  20. COMMAND ANY
  21. FlagOFF 1 (* First turn of game *)
  22. SetVariableTo 1 50 (* battery life set to 50 turns *)
  23. TurnFlagON 1 (* initialization process is over *)
  24. END_COMMAND
  25.  
  26. COMMAND ANY
  27. FlagOFF 3 (* Cooler is still cold *)
  28. CounterEquals 3 3 (* The thermometer was put in cooler three turns ago. *)
  29. SwapLocations 240 244 (* Swap for COLD thermometer *)
  30. PutInCurrentRoom 241 (* snow flake *)
  31. TurnCounterON 2 (* Count number of turns since snow flake fell *)
  32. PrintMessage 61 (* The mercury in the thermometer has fallen *)
  33. TurnFlagON 5 (* It is snowing *)
  34. PlusScore 10
  35. END_COMMAND
  36.  
  37. COMMAND ANY
  38. CounterEquals 2 10 (* Snow flake fell ten turns ago. *)
  39. Present 241 (* Snow flake is here *)
  40. PrintMessage 62 (* The first snowflake melted! *)
  41. MinusScore 10
  42. END_COMMAND
  43.  
  44. COMMAND ANY
  45. CounterEquals 2 10 (* Snow flake fell ten turns ago. *)
  46. Destroy 241 (* Snow flake melts *)
  47. MinusScore 10
  48. END_COMMAND
  49.  
  50. COMMAND ANY
  51. NOT AtLocation 61 (* starting room *)
  52. AtLocationGT 25 (* South pole *)
  53. Present 301 (* Percival is here *)
  54. Present 226 (* Egbert's Diary *)
  55. PrintMessage 55 (* Percival just stole Egbert's diary. *)
  56. Destroy 226 (* It's now gone *)
  57. MinusScore 10
  58. END_COMMAND
  59.  
  60. COMMAND ANY
  61. NOT AtLocation 61 (* starting room *)
  62. AtLocationGT 25 (* At South pole *)
  63. NOT IsWearing 207 (* NOT wearing parka *)
  64. AddToVariable 2 1 (* Increment count of times at South Pole without a parka *)
  65. VariableEquals 2 4 (* Four turns without parka *)
  66. PrintMessage 72 (* You freeze to death. *)
  67. KillPlayer
  68. MinusScore 10
  69. DoneWithTurn
  70. END_COMMAND
  71.  
  72. COMMAND ANY
  73. FlagOFF 3 (* Cooler and beer are cold *)
  74. CounterEquals 1 10 (* ten turns since first time cooler opened *)
  75. SwapLocations 230 231 (* Swap warm beer for cold beer *)
  76. TurnFlagON 3 (* Cooler and beer are now warm *)
  77. Present 229 (* cooler *)
  78. PrintMessage 44 (* The cooler has warmed up a bit. *)
  79. MinusScore 10
  80. END_COMMAND
  81.  
  82. COMMAND ANY
  83. FlagON 2 (* lantern is ON *)
  84. SubtractFromVariable 1 1 (* decrement battery life counter *)
  85. END_COMMAND
  86.  
  87. COMMAND ANY
  88. FlagON 2 (* lantern is ON *)
  89. Present 242 (* ON lantern is here *)
  90. VariableGT 1 0 (* At least one more turn for battery life *)
  91. VariableLT 1 11 (* Less than ten more turns for battery life *)
  92. PrintMessage 34 (* Your nifty lantern is flickering on and off. *)
  93. END_COMMAND
  94.  
  95. COMMAND ANY
  96. FlagON 2 (* lantern is ON *)
  97. VariableEquals 1 0 (* Last turn for battery life *)
  98. TurnFlagOFF 2 (* Lantern is OFF for good *)
  99. SwapLocations 242 243 (* Swap for DEAD lantern *)
  100. Present 242 (* ON lantern is here *)
  101. PrintMessage 35 (* Your nifty lantern flickers and goes off. *)
  102. END_COMMAND
  103.  
  104. COMMAND ANY
  105. Present 301 (* Percival is here *)
  106. AddToVariable 3 1 (* Increment count of turns Percival has been following *)
  107. AddToGroup 301 (* Have Percival follow player *)
  108. VariableEquals 3 8 (* Has been following for 8 turns *)
  109. OR
  110. VariableEquals 3 17 (* Has been following for 17 turns *)
  111. PrintMessage 78 (* So buzz off! *)
  112. END_COMMAND
  113.  
  114. COMMAND ANY
  115. Present 301 (* Percival is here *)
  116. Chance 15 (* 15% chance *)
  117. PrintMessage 80 (* Percival swims around and comes back *)
  118. END_COMMAND
  119.  
  120. COMMAND ANY
  121. Present 301 (* Percival is here *)
  122. Chance 20 (* 20% chance *)
  123. PrintMessage 87 (* Percival Penguin kicked you in the shin. *)
  124. END_COMMAND
  125.  
  126. COMMAND ANY
  127. Present 301 (* Percival is here *)
  128. VariableGT 3 19 (* Has been following for 20 turns or more *)
  129. NOT AtLocation 37 (* Percival's "home" floe *)
  130. PrintMessage 79 (* Percival throws snowball and leaves. *)
  131. SendToRoom 301 37 (* Send Percival "home" *)
  132. RemoveFromGroup 301 (* Have Percival stop following player *)
  133. SetVariableTo 3 0 (* Reset following counter to 0 *)
  134. END_COMMAND
  135.  
  136. COMMAND ANY
  137. Present 301 (* Percival is here *)
  138. VerbIsDirection (* Player trying to leave current floe *)
  139. Chance 15 (* 15% chance *)
  140. NOT AtLocation 37 (* Percival's "home" floe *)
  141. RandomMessage 81 86 (* Percival leaves in random direction. *)
  142. SendToRoom 301 37 (* Send Percival "home" *)
  143. RemoveFromGroup 301 (* Have Percival stop following player *)
  144. SetVariableTo 3 0 (* Reset following counter to 0 *)
  145. END_COMMAND
  146.  
  147.  
  148. ;COMMANDS -- Considered only for specific combinations of words
  149.  
  150.  
  151. ;ENTER COMMAND
  152.  
  153. COMMAND ENTER MIRROR
  154. FlagON 5 (* It is snowing *)
  155. PrintMessage 71 (* Nothing happens. *)
  156. DoneWithTurn
  157. END_COMMAND
  158.  
  159. COMMAND ENTER MIRROR
  160. Present 201 (* Shinny Mirror *)
  161. GoToRoom 26 (* At the ice door -- At the South Pole *)
  162. PrintMessage 69 (* You are temporarily stunned by a flash of blinding light. *)
  163. PrintMessage 70 (* The hair at the back of your neck stands straight up. *)
  164. DoneWithTurn
  165. END_COMMAND
  166.  
  167. COMMAND ENTER MIRROR
  168. AtLocation 26 (* At the ice door -- At the South Pole *)
  169. GoToRoom 2 (* Bunkhouse *)
  170. PrintMessage 69 (* You are temporarily stunned by a flash of blinding light. *)
  171. DoneWithTurn
  172. END_COMMAND
  173.  
  174. COMMAND ENTER ANY
  175. RandomMessage 1 6 (* "Bizarre" message. *)
  176. DoneWithTurn
  177. END_COMMAND
  178.  
  179. ;PUT COMMANDS
  180.  
  181. COMMAND PUT POINSETTIA IN BLENDER
  182. Present 233 (* Blender *)
  183. Present 235 (* Real Poinsettia *)
  184. Destroy 235 (* Real Poinsettia *)
  185. SendToRoom 236 233 (* Put juice in blender *)
  186. PrintMessage 65 (* It is now juice *)
  187. PlusScore 25
  188. DoneWithTurn
  189. END_COMMAND
  190.  
  191. COMMAND PUT SNOW FLAKE IN BLENDER
  192. Present 233 (* Blender *)
  193. Present 241 (* Snow flake *)
  194. IsLocated 236 233 (* The juice is in blender *)
  195. PrintMessage 66 (* It is now juice *)
  196. TurnFlagON 4 (* NOZEGLOZE is ON *)
  197. PlusScore 25
  198. DoneWithTurn
  199. END_COMMAND
  200.  
  201. COMMAND PUT SNOW FLAKE IN ANY
  202. Present 241 (* Snow flake *)
  203. PrintMessage 62 (* The snow flake melts *)
  204. Destroy 241
  205. DoneWithTurn
  206. END_COMMAND
  207.  
  208. COMMAND PUT THERMOMETER IN COOLER
  209. Present 240 (* Thermometer *)
  210. Present 229 (* Cooler *)
  211. TurnCounterON 3 (* Count number of turns since thermometer put in cooler *)
  212. END_COMMAND
  213.  
  214. COMMAND PUT HAT ON SNOWMAN
  215. Present 234 (* Silk hat *)
  216. Present 306 (* ordinary snowman *)
  217. SwapLocations 306 300 (* Snowman turns into Frosty *)
  218. PrintMessage 49 (* Must have been some magic in that old silk hat! *)
  219. Destroy 234 (* Silk hat now is part of Frosty -- on his head *)
  220. PlusScore 25
  221. DoneWithTurn
  222. END_COMMAND
  223.  
  224. COMMAND PUT ANY ON SNOWMAN
  225. Present 306 (* ordinary snowman *)
  226. OR
  227. Present 300 (* Frosty the snowman *)
  228. PrintMessage 50 (* What would a snowman want with that? *)
  229. DoneWithTurn
  230. END_COMMAND
  231.  
  232. ;GIVE COMMANDS
  233.  
  234. COMMAND GIVE STRING TO SANTA
  235. Present 302 (* Santa is here *)
  236. Present 216 (* String is here *)
  237. Destroy 216 (* It's now on Santa *)
  238. SwapLocations 302 303 (* Santa sports a green mitten string *)
  239. PrintMessage 63 (* Santa take string and uses it as a belt *)
  240. PlusScore 10
  241. DoneWithTurn
  242. END_COMMAND
  243.  
  244. COMMAND GIVE ANY TO SANTA
  245. Present 302 (* Unstrung Santa is here *)
  246. OR
  247. Present 303 (* Stringed Santa is here *)
  248. PrintMessage 64 (* Santa shakes his head and says 'I don't need that.' *)
  249. DoneWithTurn
  250. END_COMMAND
  251.  
  252. COMMAND GIVE HAT TO SNOWMAN
  253. Present 234 (* Silk hat *)
  254. Present 306 (* ordinary snowman *)
  255. SwapLocations 306 300 (* Snowman turns into Frosty *)
  256. PrintMessage 49 (* Must have been some magic in that old silk hat! *)
  257. Destroy 234 (* Silk hat is now part of Frosty -- on his head *)
  258. PlusScore 25
  259. DoneWithTurn
  260. END_COMMAND
  261.  
  262. COMMAND GIVE ANY TO SNOWMAN
  263. Present 306 (* ordinary snowman *)
  264. PrintMessage 50 (* What would a snowman want with that? *)
  265. DoneWithTurn
  266. END_COMMAND
  267.  
  268. COMMAND GIVE POINSETTIA TO SNOWMAN
  269. Present 221 (* You have the poinsettia to give *)
  270. Present 300 (* Frosty the snowman *)
  271. PrintMessage 52 (* Frosty accepts your gift graciously. *)
  272. PrintMessage 53 (* He turns them into real flowers. *)
  273. SwapLocations 221 235 (* Swap for real poinsettia *)
  274. PlusScore 10
  275. DoneWithTurn
  276. END_COMMAND
  277.  
  278. COMMAND GIVE ANY TO SNOWMAN
  279. NOUNPresent (* You have it to give *)
  280. Present 300 (* Frosty the snowman *)
  281. PrintMessage 52 (* Frosty accepts your gift graciously. *)
  282. DestroyNOUN (* It's now gone *)
  283. DoneWithTurn
  284. END_COMMAND
  285.  
  286. COMMAND GIVE ANY TO PERCIVAL
  287. NOUNPresent (* You have it to give *)
  288. Present 301 (* Percival is here *)
  289. PrintMessage 52 (* Percival grabs the $NOUN$ and stuffs it in his tuxedo pocket. *)
  290. DestroyNOUN (* It's now gone *)
  291. DoneWithTurn
  292. END_COMMAND
  293.  
  294. COMMAND GIVE JUICE TO RUDOLPH
  295. Present 236 (* Poinsettia Juice *)
  296. FlagON 4 (* NOZEGLOZE flag is ON *)
  297. PrintMessage 56 (* It does the trick ... You win! *)
  298. Destroy 236
  299. PlusScore 50
  300. WinGame
  301. DoneWithTurn
  302. END_COMMAND
  303.  
  304. COMMAND GIVE JUICE TO RUDOLPH
  305. Present 236 (* Poinsettia Juice *)
  306. FlagOFF 4 (* NOZEGLOZE flag is OFF *)
  307. PrintMessage 57 (* You screwed up and lose game! *)
  308. Destroy 236
  309. MinusScore 50
  310. EndGame
  311. DoneWithTurn
  312. END_COMMAND
  313.  
  314. COMMAND GIVE ANY TO RUDOLPH
  315. NOUNPresent (* You have it to give *)
  316. PrintMessage 58 (* Rudolph doesn't appear to be interested. *)
  317. DoneWithTurn
  318. END_COMMAND
  319.  
  320. ;TAKE or GET COMMANDS
  321.  
  322. COMMAND GET PAPER
  323. AtLocation 5 (* Gift wrap room *)
  324. PrintMessage 22 (* Sorry, but you don't have time to mess with the $NOUN$.*)
  325. DoneWithTurn
  326. END_COMMAND
  327.  
  328. COMMAND TAKE SNOW FLAKE
  329. Present 241 (* It is here *)
  330. PrintMessage 60 (* It's starting to snow EVERYWHERE! *)
  331. GetNOUN (* You wanted it -- you got it. *)
  332. DoneWithTurn
  333. END_COMMAND
  334.  
  335. ;DROP COMMANDS
  336.  
  337. COMMAND DROP ANY
  338. NOUNPresent (* You have it to drop *)
  339. Present 301 (* Percival is here *)
  340. PrintMessage 52 (* Percival grabs the $NOUN$ and stuffs it in his tuxedo pocket. *)
  341. DestroyNOUN (* It's now gone *)
  342. DoneWithTurn
  343. END_COMMAND
  344.  
  345. ;The above meta-command will make if very difficult to use the traditional
  346. ;maze mapping technique of dropping items in various locations.
  347.  
  348. ;MAKE COMMANDS
  349.  
  350. COMMAND MAKE SNOWMAN
  351. NOT AtLocation 61 (* starting room *)
  352. AtLocationGT 25 (* South pole *)
  353. PrintMessage 46 (* It's too cold here to build a snowman here.
  354. DoneWithTurn
  355. END_COMMAND
  356.  
  357. COMMAND MAKE SNOWMAN
  358. NOT AtLocation 21 (* On the runway *)
  359. PrintMessage 47 (* You can't build a snowman here. *)
  360. DoneWithTurn
  361. END_COMMAND
  362.  
  363. COMMAND MAKE SNOWMAN
  364. IsNowhere 306 (* Ordinary snowman *)
  365. IsNowhere 300 (* Frosty the snowman *)
  366. AtLocation 21 (* On the runway *)
  367. PrintMessage 48 (* Okay, you build a snowman. *)
  368. PutInCurrentRoom 306 (* Ordinary snowman *)
  369. PlusScore 10
  370. DoneWithTurn
  371. END_COMMAND
  372.  
  373. COMMAND MAKE ANY
  374. PrintMessage 22 (* Don't dilly dally! *)
  375. DoneWithTurn
  376. END_COMMAND
  377.  
  378. ;DRINK COMMANDS
  379.  
  380. COMMAND DRINK JUICE
  381. Present 236 (* Juice *)
  382. PrintMessage 73 (* Dumb! Dumb! Dumb! *)
  383. Destroy 236
  384. DoneWithTurn
  385. END_COMMAND
  386.  
  387. COMMAND DRINK BEER
  388. Present 231 (* Warm beer *)
  389. PrintMessage 45 (* YECH!!!  You decide not to drink it. *)
  390. DoneWithTurn
  391. END_COMMAND
  392.  
  393. COMMAND DRINK BEER
  394. Present 230 (* Cold beer *)
  395. PrintMessage 54 (* Cold beer!!!  You drink them all. *)
  396. SwapLocations 230 232 (* Swap beer for empty bottles *)
  397. PlusScore 10
  398. DoneWithTurn
  399. END_COMMAND
  400.  
  401. COMMAND DRINK ANY
  402. RandomMessage 1 6 (* "Bizarre" message *)
  403. DoneWithTurn
  404. END_COMMAND
  405.  
  406. ;READ COMMANDS
  407.  
  408. COMMAND READ DIARY
  409. Present 226 (* Santa's Diary *)
  410. RandomMessage 25 33 (* randomly display a page from the diary *)
  411. DoneWithTurn
  412. END_COMMAND
  413.  
  414. ;UNLOCK COMMANDS
  415.  
  416. COMMAND UNLOCK MIDDLE DRAWER WITH KEY
  417. Present 210 (* Brass key *)
  418. Present 203 (* Middle Drawer *)
  419. ObjectIsNumber 210 (* Brass key *)
  420. NOUNIsNumber 203 (* Middle Drawer *)
  421. SwapLocations 210 211 (* Swap for broken key *)
  422. PrintMessage 59 (* The brass key breaks off in lock *)
  423. UnLockIt 203 (* unlock the middle drawer *)
  424. DoneWithTurn
  425. END_COMMAND
  426.  
  427. ;OPEN COMMANDS
  428.  
  429. COMMAND OPEN COOLER
  430. Present 229 (* cooler *)
  431. CounterEquals 1 0 (* first time cooler opened *)
  432. TurnCounterON 1 (* start counter for number of turns since cooler opened *)
  433. END_COMMAND
  434.  
  435. COMMAND OPEN DIARY
  436. Present 226 (* Santa's Diary *)
  437. RandomMessage 25 33 (* randomly display a page from the diary *)
  438. DoneWithTurn
  439. END_COMMAND
  440.  
  441. COMMAND OPEN DOOR
  442. AtLocation 27 (* At the ice door *)
  443. GoToRoom 28 (* Inside, near door *)
  444. PrintMessage 88 (* You enter the room in the hill. *)
  445. DoneWithTurn
  446. END_COMMAND
  447.  
  448. COMMAND OPEN DOOR
  449. AtLocation 28 (* Inside, near door *)
  450. GoToRoom 27 (* At the ice door *)
  451. PrintMessage 89 (* You leave the room in the hill. *)
  452. DoneWithTurn
  453. END_COMMAND
  454.  
  455. ;SIT COMMANDS
  456.  
  457. COMMAND SIT ANY
  458. AtLocation 6 (* Santa's Office *)
  459. PrintMessage 24 (* You don't have time to sit down! *)
  460. DoneWithTurn
  461. END_COMMAND
  462.  
  463. ;LIGHT COMMANDS
  464.  
  465. COMMAND LIGHT LANTERN
  466. Present 205 (* OFF lantern is here *)
  467. TurnFlagON 2 (* lantern is now ON *)
  468. SwapLocations 242 205 (* Swap for ON lantern *)
  469. PrintMessage 36 (* Your lantern is now on. *)
  470. DoneWithTurn
  471. END_COMMAND
  472.  
  473. COMMAND LIGHT LANTERN
  474. Present 242 (* ON lantern is here *)
  475. PrintMessage 38 (* The lantern is already on. *)
  476. DoneWithTurn
  477. END_COMMAND
  478.  
  479. COMMAND LIGHT LANTERN
  480. Present 243 (* DEAD lantern is here *)
  481. PrintMessage 39 (* Sorry, but this lantern has had it. *)
  482. DoneWithTurn
  483. END_COMMAND
  484.  
  485. ;EXTINGUISH COMMANDS
  486.  
  487. COMMAND EXTINGUISH LANTERN
  488. Present 242 (* ON lantern is here *)
  489. TurnFlagOFF 2 (* lantern is now OFF *)
  490. SwapLocations 242 205 (* Swap for OFF lantern *)
  491. PrintMessage 37 (* Your lantern is now off. *)
  492. DoneWithTurn
  493. END_COMMAND
  494.  
  495. COMMAND EXTINGUISH LANTERN
  496. Present 243 (* DEAD lantern is here *)
  497. OR
  498. Present 205 (* OFF lantern is here *)
  499. PrintMessage 40 (* Sorry, but this lantern is already OFF. *)
  500. DoneWithTurn
  501. END_COMMAND
  502.  
  503. ;TURN COMMANDS
  504.  
  505. COMMAND TURN LANTERN
  506. PrintMessage 41 (* Please use LIGHT LANTERN and EXTINGUISH LANTERN. *)
  507. DoneWithTurn
  508. END_COMMAND
  509.  
  510. ;WEAR COMMANDS
  511.  
  512. COMMAND WEAR MITTENS
  513. Present 214 (* Left mitten is here *)
  514. Present 215 (* Right mitten is here also *)
  515. PrintMessage 90 (* You put on the right mitten *)
  516. PrintMessage 91 (* You put on the left mitten *)
  517. DoneWithTurn
  518. END_COMMAND
  519.  
  520. COMMAND WEAR MITTENS
  521. Present 214 (* Left mitten is here *)
  522. PrintMessage 91 (* You put on the left mitten *)
  523. DoneWithTurn
  524. END_COMMAND
  525.  
  526. COMMAND WEAR MITTENS
  527. Present 215 (* Right mitten is here *)
  528. PrintMessage 90 (* You put on the right mitten *)
  529. DoneWithTurn
  530. END_COMMAND
  531.  
  532. ;TIE and UNTIE COMMANDS
  533.  
  534. COMMAND UNTIE MITTENS
  535. Present 213 (* Tied mittens are here *)
  536. SwapLocations 213 214 (* Swap left mitten for tied pair *)
  537. SendToItem 215 214 (* Move right mitten also *)
  538. SendToItem 216 214 (* Move string also *)
  539. PrintMessage 42 (* You untie the mittens *)
  540. PlusScore 10
  541. DoneWithTurn
  542. END_COMMAND
  543.  
  544. COMMAND UNTIE STRING
  545. Present 213 (* Tied mittens are here *)
  546. SwapLocations 213 214 (* Swap left mitten for tied pair *)
  547. SendToItem 215 214 (* Move right mitten also *)
  548. SendToItem 216 214 (* Move string also *)
  549. PrintMessage 42 (* You untie the mittens *)
  550. PlusScore 10
  551. DoneWithTurn
  552. END_COMMAND
  553.  
  554. COMMAND TIE MITTENS
  555. Present 216 (* string is here *)
  556. PrintMessage 43 (* You can't do it. *)
  557. DoneWithTurn
  558. END_COMMAND
  559.  
  560. COMMAND TIE STRING TO MITTENS
  561. Present 216 (* string is here *)
  562. PrintMessage 43 (* You can't do it. *)
  563. DoneWithTurn
  564. END_COMMAND
  565.  
  566. COMMAND TIE ANY
  567. PrintMessage 22 (* Sorry, but you don't have time to mess with the $NOUN$.*)
  568. DoneWithTurn
  569. END_COMMAND
  570.  
  571. ;TALK and ASK COMMANDS
  572.  
  573. COMMAND TALK TO ELF
  574. PrintMessage 22 (* Sorry, but you don't have time to mess with the $NOUN$.*)
  575. DoneWithTurn
  576. END_COMMAND
  577.  
  578. COMMAND ASK ELF
  579. PrintMessage 22 (* Sorry, but you don't have time to mess with the $NOUN$.*)
  580. DoneWithTurn
  581. END_COMMAND
  582.  
  583. ;EXAMINE COMMANDS
  584.  
  585. COMMAND EXAMINE DRAWER
  586. AtLocation 6 (* Santa's Office *)
  587. PrintMessage 23 (* It has an ornate gold lock *)
  588. DoneWithTurn
  589. END_COMMAND
  590.   
  591. COMMAND EXAMINE PAPER
  592. AtLocation 5 (* Gift wrap room *)
  593. DescribeThing 220 (* describe paper, etc....*)
  594. DoneWithTurn
  595. END_COMMAND
  596.  
  597. COMMAND EXAMINE ELF
  598. DescribeThing 305 (* From where you're standing you can't see the elf's face. *)
  599. DoneWithTurn
  600. END_COMMAND
  601.  
  602. COMMAND EXAMINE PATH
  603. PrintMessage 11 (* The path disappears in the fog. *)
  604. DoneWithTurn
  605. END_COMMAND
  606.  
  607. ;LOOK COMMANDS
  608.  
  609. COMMAND LOOK ANY
  610. AtLocation 61 (* In octagonal room *)
  611. PrintMessage 21 (* You can barely turn around in here. *)
  612. DoneWithTurn
  613. END_COMMAND
  614.  
  615. COMMAND LOOK ANY
  616. AtLocation 3 (* Elves' Closet *)
  617. PrintMessage 7 (* This closet seems very familiar. *)
  618. DoneWithTurn
  619. END_COMMAND
  620.  
  621. COMMAND LOOK ANY
  622. AtLocation 4 (* Santa's Workshop *)
  623. PrintMessage 8 (* Lengthy description of workshop *)
  624. DoneWithTurn
  625. END_COMMAND
  626.  
  627. COMMAND LOOK ANY
  628. AtLocation 5 (* Gift Wrapping Room *)
  629. PrintMessage 9 (* What are you looking for?  Need to wrap a gift? *)
  630. DoneWithTurn
  631. END_COMMAND
  632.  
  633. COMMAND LOOK ANY
  634. AtLocation 6 (* Santa's Office *)
  635. PrintMessage 10 (* The desk and the computer look interesting *)
  636. DoneWithTurn
  637. END_COMMAND
  638.  
  639. COMMAND LOOK ANY
  640. AtLocation 9 (* Outside the workshop *)
  641. PrintMessage 12 (* The fog is so dense you can only see a few metres. *)
  642. DoneWithTurn
  643. END_COMMAND
  644.  
  645. COMMAND LOOK ANY
  646. AtLocation 22 (* In the reindeer barn *)
  647. PrintMessage 13 (* You notice an enormous set of doors leading northeast. *)
  648. DoneWithTurn
  649. END_COMMAND
  650.  
  651. COMMAND LOOK ANY
  652. AtLocation 27 (* Outside near the door *)
  653. PrintMessage 14 (* The door is closed. *)
  654. DoneWithTurn
  655. END_COMMAND
  656.  
  657. COMMAND LOOK ANY
  658. AtLocation 28 (* Inside near the door *)
  659. PrintMessage 15 (* The door is closed. *)
  660. DoneWithTurn
  661. END_COMMAND
  662.  
  663. COMMAND LOOK ANY
  664. AtLocation 29 (* Inside the room in the hill *)
  665. PrintMessage 16 (* Another description of room. *)
  666. DoneWithTurn
  667. END_COMMAND
  668.  
  669. COMMAND LOOK ANY
  670. AtLocation 30 (* Inside the narrow passage *)
  671. PrintMessage 17 (* You don't discover anything new about the passage. *)
  672. DoneWithTurn
  673. END_COMMAND
  674.  
  675. COMMAND LOOK ANY
  676. AtLocation 31 (* Dead End *)
  677. PrintMessage 18 (* You discover a piece of lined paper. *)
  678. DoneWithTurn
  679. END_COMMAND
  680.  
  681. COMMAND LOOK ANY
  682. AtLocation 32 (* On ice plain1 *)
  683. OR
  684. AtLocation 33 (* On ice plain2 *)
  685. OR
  686. AtLocation 34 (* On ice plain3 *)
  687. PrintMessage 19 (* Long, poetic description of ice plain *)
  688. DoneWithTurn
  689. END_COMMAND
  690.  
  691. COMMAND LOOK ANY
  692. AtLocation 45 (* In the crystal ice garden *)
  693. PrintMessage 20 (* a herd of reindeer stampeded through here. *)
  694. DoneWithTurn
  695. END_COMMAND
  696.  
  697. ;ATTACK COMMANDS
  698.  
  699. COMMAND ATTACK ANY
  700. PrintMessage 67 (* Such behaviour would be most unbecoming of a Christmas elf *)
  701. MinusScore 10
  702. DoneWithTurn
  703. END_COMMAND
  704.  
  705. ;HELP COMMANDS
  706.  
  707. COMMAND HELP ANY
  708. PrintMessage 68 (* That's right.  You're here to help Santa. *)
  709. DoneWithTurn
  710. END_COMMAND
  711.  
  712. ;QUIT COMMANDS
  713.  
  714. COMMAND QUIT
  715. PrintMessage 74 (* Do you really want to quit? *)
  716. PromptForYes (* Get YES or NO answer from keyboard *)
  717. PrintMessage 75 (* Thank you for playing Elves! *)
  718. EndGame (* OK, player entered YES -- so let's quit *)
  719. DoneWithTurn
  720. END_COMMAND
  721.  
  722. COMMAND QUIT
  723. PrintMessage 76 (* I didn't think you really wanted to quit! *)
  724. BlankLine
  725. ReDirectTo LOOK
  726. DoneWithTurn (* NO answer -- Ignore "Standard" AGT QUIT routine *)
  727. END_COMMAND
  728.  
  729. ;RUB COMMANDS
  730.  
  731. COMMAND RUB
  732. NOUNPresent
  733. PrintMessage 77 (* You $VERB$ the $NOUN$, but nothing happens. *)
  734. DoneWithTurn
  735. END_COMMAND
  736.  
  737. ;SEARCH COMMANDS
  738.  
  739. COMMAND SEARCH THE TOP DRAWER
  740. Present 202 (* Top drawer is here *)
  741. NOUNIsNumber 202 (* The top drawer was specified in input *)
  742. IsLocked 202 (* The top drawer is locked *)
  743. PrintMessage 94 (* The $ADJECTIVE$ $NOUN$ is locked. *)
  744. DoneWithTurn
  745. END_COMMAND
  746.  
  747. COMMAND SEARCH THE TOP DRAWER
  748. Present 202 (* Top drawer is here *)
  749. NOUNIsNumber 202 (* The top drawer was specified in input *)
  750. IsUnLocked 202 (* The top drawer is unlocked *)
  751. OpenIt 202 (* Open the top drawer -- first *)
  752. NOT SomethingInside 202 (* The top drawer is empty. *)
  753. PrintMessage 95 (* The $ADJECTIVE$ $NOUN$ is empty. *)
  754. DoneWithTurn
  755. END_COMMAND
  756.  
  757. COMMAND SEARCH THE TOP DRAWER
  758. Present 202 (* Top drawer is here *)
  759. NOUNIsNumber 202 (* The top drawer was specified in input *)
  760. IsUnLocked 202 (* The top drawer is unlocked *)
  761. OpenIt 202 (* Open the top drawer -- first *)
  762. SomethingInside 202 (* The top drawer is NOT empty. *)
  763. PrintMessage 96 (* The $ADJECTIVE$ $NOUN$ contains: *)
  764. ShowContents 202 (* Display contents of top drawer *)
  765. DoneWithTurn
  766. END_COMMAND
  767.  
  768. COMMAND SEARCH THE MIDDLE DRAWER
  769. Present 203 (* Middle drawer is here *)
  770. NOUNIsNumber 203 (* The middle drawer was specified in input *)
  771. IsLocked 203 (* The middle drawer is locked *)
  772. PrintMessage 94 (* The $ADJECTIVE$ $NOUN$ is locked. *)
  773. DoneWithTurn
  774. END_COMMAND
  775.  
  776. COMMAND SEARCH THE MIDDLE DRAWER
  777. Present 203 (* Middle drawer is here *)
  778. NOUNIsNumber 203 (* The middle drawer was specified in input *)
  779. IsUnLocked 203 (* The middle drawer is unlocked *)
  780. OpenIt 203 (* Open the middle drawer -- first *)
  781. NOT SomethingInside 203 (* The middle drawer is empty. *)
  782. PrintMessage 95 (* The $ADJECTIVE$ $NOUN$ is empty. *)
  783. DoneWithTurn
  784. END_COMMAND
  785.  
  786. COMMAND SEARCH THE MIDDLE DRAWER
  787. Present 203 (* Middle drawer is here *)
  788. NOUNIsNumber 203 (* The middle drawer was specified in input *)
  789. IsUnLocked 203 (* The middle drawer is unlocked *)
  790. OpenIt 203 (* Open the middle drawer -- first *)
  791. SomethingInside 203 (* The middle drawer is NOT empty. *)
  792. PrintMessage 96 (* The $ADJECTIVE$ $NOUN$ contains: *)
  793. ShowContents 203 (* Display contents of middle drawer *)
  794. DoneWithTurn
  795. END_COMMAND
  796.  
  797. COMMAND SEARCH THE BOTTOM DRAWER
  798. Present 204 (* Bottom drawer is here *)
  799. NOUNIsNumber 204 (* The bottom drawer was specified in input *)
  800. IsLocked 204 (* The bottom drawer is locked *)
  801. PrintMessage 94 (* The $ADJECTIVE$ $NOUN$ is locked. *)
  802. DoneWithTurn
  803. END_COMMAND
  804.  
  805. COMMAND SEARCH THE BOTTOM DRAWER
  806. Present 204 (* Bottom drawer is here *)
  807. NOUNIsNumber 204 (* The bottom drawer was specified in input *)
  808. IsUnLocked 204 (* The bottom drawer is unlocked *)
  809. OpenIt 204 (* Open the bottom drawer -- first *)
  810. NOT SomethingInside 204 (* The bottom drawer is empty. *)
  811. PrintMessage 95 (* The $ADJECTIVE$ $NOUN$ is empty. *)
  812. DoneWithTurn
  813. END_COMMAND
  814.  
  815. COMMAND SEARCH THE BOTTOM DRAWER
  816. Present 204 (* Bottom drawer is here *)
  817. NOUNIsNumber 204 (* The bottom drawer was specified in input *)
  818. IsUnLocked 204 (* The bottom drawer is unlocked *)
  819. OpenIt 204 (* Open the bottom drawer -- first *)
  820. SomethingInside 204 (* The bottom drawer is NOT empty. *)
  821. PrintMessage 96 (* The $ADJECTIVE$ $NOUN$ contains: *)
  822. ShowContents 204 (* Display contents of bottom drawer *)
  823. DoneWithTurn
  824. END_COMMAND
  825.  
  826. COMMAND SEARCH THE DESK
  827. Present 224 (* Santa's desk is here *)
  828. NOUNIsNumber 224 (* Santa's desk was specified in input *)
  829. IsLocked 224 (* Santa's desk is locked *)
  830. PrintMessage 94 (* The $ADJECTIVE$ $NOUN$ is locked. *)
  831. DoneWithTurn
  832. END_COMMAND
  833.  
  834. COMMAND SEARCH THE DESK
  835. Present 224 (* Santa's desk is here *)
  836. NOUNIsNumber 224 (* Santa's desk was specified in input *)
  837. IsUnLocked 224 (* Santa's desk is unlocked *)
  838. OpenIt 224 (* Open Santa's desk -- first *)
  839. NOT SomethingInside 224 (* Santa's desk is empty. *)
  840. PrintMessage 95 (* The $ADJECTIVE$ $NOUN$ is empty. *)
  841. DoneWithTurn
  842. END_COMMAND
  843.  
  844. COMMAND SEARCH THE DESK
  845. Present 224 (* Santa's desk is here *)
  846. NOUNIsNumber 224 (* Santa's desk was specified in input *)
  847. IsUnLocked 224 (* Santa's desk is unlocked *)
  848. OpenIt 224 (* Open Santa's desk -- first *)
  849. SomethingInside 224 (* Santa's desk is NOT empty. *)
  850. PrintMessage 96 (* The $ADJECTIVE$ $NOUN$ contains: *)
  851. ShowContents 224 (* Display contents of Santa's desk *)
  852. DoneWithTurn
  853. END_COMMAND
  854.  
  855. COMMAND SEARCH RIGHT POCKET
  856. Present 208 (* Right pocket of parka is here *)
  857. NOUNIsNumber 208 (* Right pocket of parka was specified in input *)
  858. OpenIt 208 (* Open right pocket -- first *)
  859. NOT SomethingInside 208 (* Right pocket is empty. *)
  860. PrintMessage 93 (* You open the $ADJECTIVE$ $NOUN$. *)
  861. PrintMessage 95 (* The $ADJECTIVE$ $NOUN$ is empty. *)
  862. DoneWithTurn
  863. END_COMMAND
  864.  
  865. COMMAND SEARCH RIGHT POCKET
  866. Present 208 (* Right pocket of parka is here *)
  867. NOUNIsNumber 208 (* Right pocket of parka was specified in input *)
  868. OpenIt 208 (* Open right pocket -- first *)
  869. SomethingInside 208 (* Right pocket is NOT empty. *)
  870. PrintMessage 93 (* You open the $ADJECTIVE$ $NOUN$. *)
  871. PrintMessage 96 (* The $ADJECTIVE$ $NOUN$ contains: *)
  872. ShowContents 208 (* Display contents of Right Pocket *)
  873. DoneWithTurn
  874. END_COMMAND
  875.  
  876. COMMAND SEARCH LEFT POCKET
  877. Present 209 (* Left pocket of parka is here *)
  878. NOUNIsNumber 209 (* Left pocket of parka was specified in input *)
  879. OpenIt 209 (* Open left pocket -- first *)
  880. NOT SomethingInside 209 (* Left pocket is empty. *)
  881. PrintMessage 93 (* You open the $ADJECTIVE$ $NOUN$. *)
  882. PrintMessage 95 (* The $ADJECTIVE$ $NOUN$ is empty. *)
  883. DoneWithTurn
  884. END_COMMAND
  885.  
  886. COMMAND SEARCH LEFT POCKET
  887. Present 209 (* Left pocket of parka is here *)
  888. NOUNIsNumber 209 (* Left pocket of parka was specified in input *)
  889. OpenIt 209 (* Open left pocket -- first *)
  890. SomethingInside 209 (* Left pocket is NOT empty. *)
  891. PrintMessage 93 (* You open the $ADJECTIVE$ $NOUN$. *)
  892. PrintMessage 96 (* The $ADJECTIVE$ $NOUN$ contains: *)
  893. ShowContents 209 (* Display contents of Left Pocket *)
  894. DoneWithTurn
  895. END_COMMAND
  896.  
  897. COMMAND SEARCH COOLER
  898. Present 229 (* Cooler is here *)
  899. NOUNIsNumber 229 (* Cooler was specified in input *)
  900. OpenIt 229 (* Open Cooler -- first *)
  901. NOT SomethingInside 229 (* Cooler is empty. *)
  902. PrintMessage 93 (* You open the $ADJECTIVE$ $NOUN$. *)
  903. PrintMessage 95 (* The $ADJECTIVE$ $NOUN$ is empty. *)
  904. DoneWithTurn
  905. END_COMMAND
  906.  
  907. COMMAND SEARCH COOLER
  908. Present 229 (* Cooler is here *)
  909. NOUNIsNumber 229 (* Cooler was specified in input *)
  910. OpenIt 229 (* Open Cooler -- first *)
  911. SomethingInside 229 (* Cooler is NOT empty. *)
  912. PrintMessage 93 (* You open the $ADJECTIVE$ $NOUN$. *)
  913. PrintMessage 96 (* The $ADJECTIVE$ $NOUN$ contains: *)
  914. ShowContents 229 (* Display contents of Cooler *)
  915. DoneWithTurn
  916. END_COMMAND
  917.  
  918. COMMAND SEARCH ROOM
  919. ReDirectTo LOOK
  920. DoneWithTurn
  921. END_COMMAND
  922.  
  923. COMMAND SEARCH ANY
  924. RandomMessage 1 6 (* "Bizarre" message *)
  925. DoneWithTurn
  926. END_COMMAND
  927.  
  928. ;SNEEZE COMMAND
  929.  
  930. COMMAND SNEEZE
  931. AtLocation 61 (* staring room *)
  932. PrintMessage 97 (* The entire room of elves echoes your sneeze...ACHHOOO! *)
  933. DoneWithTurn
  934. END_COMMAND
  935.  
  936. COMMAND SNEEZE
  937. PrintMessage 98 (* God bless you! *)
  938. DoneWithTurn
  939. END_COMMAND
  940.  
  941. ;DEBUG COMMAND
  942.  
  943. COMMAND DEBUG
  944. ToggleFlag 0
  945. DoneWithTurn
  946. END_COMMAND
  947.  
  948. ;DEBUG COMMAND
  949.  
  950. COMMAND DEBUG
  951. ToggleFlag 0
  952. DoneWithTurn
  953. END_COMMAND
  954.  
  955.